﻿#include "Chorus.h"
#include "BufferDelayer.h"

#ifdef USEJNI
#include "Chorus_JNI.h"
using namespace yzrilyzr_dsp;
using namespace yzrilyzr_util;
JNIEXPORT jlong JNICALL Java_yzrilyzr_dsp_Chorus_constructor(JNIEnv*, jobject, jdouble rate, jdouble depthInMs, jdouble mix, jdouble feedback) {
	Chorus* ptr = new Chorus(rate, depthInMs, mix, feedback);
	return reinterpret_cast<jlong>(ptr);
}
JNIEXPORT void JNICALL Java_yzrilyzr_dsp_Chorus_set(JNIEnv*, jobject, jlong ptr1, jdouble rate, jdouble depth, jdouble mix, jdouble feedback) {
	Chorus* ptr = reinterpret_cast<Chorus*>(ptr1);
	ptr->setRate(rate);
	ptr->setMix(mix);
	ptr->setDepth(depth);
	ptr->setFeedback(feedback);
}
#endif